using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.Graphics;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace GameForKids
{
    class Suport
    {
        public static ContentManager Content;
        public static Random Random = new Random(DateTime.Now.Millisecond);
        public static Dictionary<String, Texture2D> Textures = new Dictionary<string,Texture2D>();
        public static Dictionary<String, SoundEffect> SoundEffects = new Dictionary<string, SoundEffect>();
        public static Texture2D GetTexture(String link)
        {
            if (Textures.ContainsKey(link) == false)
            {
                Textures.Add(link, Content.Load<Texture2D> (link));
            }
            return Textures[link];
        }

        public static SoundEffect GetSound(String link)
        {
            if (SoundEffects.ContainsKey(link) == false)
            {
                SoundEffects.Add(link, Content.Load<SoundEffect>(link));
            }
            return SoundEffects[link];
        }
    }
}
